package com.dyc.maitaole.service.impl;

import com.dyc.maitaole.dao.CategoryDAO;
import com.dyc.maitaole.entity.Category;
import com.dyc.maitaole.service.CategoryService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class CategoryServiceImpl implements CategoryService {
    @Autowired
    private CategoryDAO categoryDAO;

    public List<Category> findAllCategories() {
        List<Category> categories = categoryDAO.queryCategories();
        return categories;
    }

}
